<!--
 * Copyright (c) 2017-2020 Contributors to the Eclipse Foundation
 *
 * See the NOTICE file(s) distributed with this work for additional
 * information regarding copyright ownership.
 *
 * This program and the accompanying materials are made available under the
 * terms of the Eclipse Public License 2.0 which is available at
 * http://www.eclipse.org/legal/epl-2.0, or the Apache Software License 2.0
 * which is available at https://www.apache.org/licenses/LICENSE-2.0.
 *
 * SPDX-License-Identifier: EPL-2.0 OR Apache-2.0
-->

<div *wineryRepositoryHideOnFeature="'yaml'">
    <winery-toscatype-table *ngIf="deploymentArtifacts && deploymentArtifacts.length > 0"
                            [tableType]="tableTypes.DeploymentArtifacts"
                            [currentNodeData]="currentNodeData"
                            [toscaTypeData]="deploymentArtifacts">
    </winery-toscatype-table>
    <div *ngIf="!deploymentArtifacts || deploymentArtifacts.length === 0" style="color: dimgray; text-align: center">
        <span>No deployment artifacts defined <br> for this Node Template.</span>
    </div>
</div>

<div *wineryRepositoryShowOnFeature="'yaml'">
    <winery-toscatype-table *ngIf="yamlArtifacts && yamlArtifacts.length > 0"
                            [tableType]="tableTypes.YamlArtifacts"
                            [currentNodeData]="currentNodeData"
                            [toscaTypeData]="yamlArtifacts">
    </winery-toscatype-table>
    <div *ngIf="!yamlArtifacts || yamlArtifacts.length === 0" style="color: dimgray; text-align: center">
        <span>No artifacts defined for <br> this Node Template.</span>
    </div>
</div>
<div *ngIf="!readonly" class="button-wrapper">
    <div (click)="toggleModal($event);" class="btn btn-sm btn-modal" style="display: block;">
        Add new {{this.configurationService.isYaml() ? 'Artifact' : 'Deployment Artifact'}}
    </div>
</div>

